home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Champak Vol A-4
/
(Vol A-4) Vol. A4.iso
/
Games
/
selfstorage.swf
/
scripts
/
frame_5
/
PlaceObject2_184_456
/
CLIPACTIONRECORD on(press).as
next >
Wrap
Text File
|
2008-03-17
|
2KB
|
54 lines
on(press){
if(_root.int_spiellaeuft == 0)
{
startTime = new Date();
_root.startzeit = startTime.getTime();
_root.int_spiellaeuft = 1;
trace("START");
}
if(_root.int_boxennummer == this.int_boxennummer)
{
if(_root.int_soundon == 1)
{
_root.mc_sounds.anhaengen.start(0,1);
}
this.int_aktiviert = 1;
dragging = 1;
int_absturz = 0;
mausx = this._xmouse;
mausy = this._ymouse;
trace("\n\nMausX: " + mausx + "\nMausY: " + mausy);
vTan = Number(mausx) / Number(mausy);
arkusTanB = Math.atan(vTan);
haltepunktwinkel = (- arkusTanB / 3.141592653589793) * 180;
if(mausy >= 0)
{
if(mausx > 0)
{
haltepunktwinkel += 180;
}
else
{
haltepunktwinkel -= 180;
}
}
trace("haltepunktwinkel: " + haltepunktwinkel);
haltepunktdistanz = Math.sqrt(mausx * mausx + mausy * mausy);
trace("numb_rotationsbeschleunigung: " + numb_rotationsbeschleunigung);
trace("v_y: " + v_y);
trace("v_x: " + v_x);
objektrotation = this._rotation;
startwinkel = 0;
abweichungswinkel = haltepunktwinkel + this._rotation;
if(abweichungswinkel > 180)
{
abweichungswinkel -= 360;
}
if(abweichungswinkel < -180)
{
abweichungswinkel += 360;
}
trace("abweichungswinkel: " + abweichungswinkel);
}
}